<%@ taglib uri="/WEB-INF/struts-logic.tld" prefix="logic" %>
<%@ taglib uri="/WEB-INF/struts-html.tld" prefix="html" %>

<html>
<head>
</head>

<body>
<table width="99%"  border="0" cellpadding="0" cellspacing="0" widtd="100%">
 
  <tr> 
    <td height="25" colspan="12" align="center" class="titulosenblanco">
      <P>
        <strong>REPORTE DE USUARIOS</strong>
      </P>
      <P></P>
    </td>  
  </tr>
  
  <html:form action="/Reportes/Usuarios/GenerarReporteUsuarios.do" target="blank" method="post">     
  <input type="hidden" name="search" value="search">
  <tr align="left">
    <td width="100%" align="center"> 
		<table width="70%" border="0" cellpadding="3" cellspacing="3">
        <tr> 
          <td width="7%">&nbsp;</td>
          <td width="22%" align="left" class="celdatabla"><strong>Usuario</strong> 
            </td>
          <td width="61%"><html:text size= "40" styleClass="form" property="name" maxlength="40" value=""/></td>
          <td width="10%">&nbsp;</td>
        </tr>				
        <tr> 
          <td width="7%">&nbsp;</td>
          <td width="22%" align="left" class="celdatabla"><strong>Grupo de usuario</strong> 
            </td>
          <td width="61%">
              <html:select styleClass="form" property="userGroupCode" style="width:215" >
                <html:option value="">Seleccione un Grupo</html:option>
                <html:options collection="userGroups" property="code" labelProperty="name" /> 
              </html:select>
          </td>
          <td width="10%">&nbsp;</td>
        </tr>
        <tr>
        <td width="7%">&nbsp;</td>
        <td width="22%" align="left" class="celdatabla"><strong>Secretarias:</strong> 
            </td>
    <td width="61%">
      <logic:notPresent name="areas">
        <DIV align="center">
          <%= request.getAttribute("msg")%>
           <%request.removeAttribute("msg");%>
        </DIV>
      </logic:notPresent>
       <%   Object codeArea = request.getParameter("code"); 
            if(codeArea==null) codeArea = "nulo";
       %>
        <div align="left">
          <logic:present name="areas">
            <logic:iterate id="area" name="areas" length="1" type="com.cs.beneficios.business.model.AreaVO">
              <html:select name="area" property="code" title="Area" styleClass="form" value="<%=(String)codeArea%>">
              <option value="" selected="selected">Seleccione una secretaria</option>
                <html:options name="area" labelName="codeArea" labelProperty="nombre" property="code" collection="areas"/>
              </html:select>
            </logic:iterate>
          </logic:present>
        </div>
    </td>

        <tr> 
          <td width="7%">&nbsp;</td>
          <td width="22%">&nbsp;</td>
          <td width="61%"><input type="submit" name="Submit" value="Buscar" > </td>
          <td width="10%">&nbsp;</td>
        </tr>
      </table>
	</td>
  </tr>
</html:form> 	
</table>
</body>
</html>
